.nav {
    top: 40%;
    position: relative;
}

/* 导航栏元素 */
.nav a {
    text-decoration: none;
    font-weight: bold;
    position: relative;
    float: left;
    width: 100px;
    line-height: 40px;
    text-align: center;
    font-size: 14px;
    color: #000;
    z-index: 1;
}

/* 底部线条 */
.line {
    position: absolute;
    top: 45px;
    left: 15px;
    /* 线的高和宽 */
    height: 3px;
    width: 70px;
    background-color: lightgrey;
    transition: all 0.3s;
}

/* 当前选中 */
.selected {
    color: blue !important;
}




